home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / vol_400 / 415_02 / rtti / rtti.head < prev    next >
Encoding:
Text File  |  1993-10-05  |  1.2 KB  |  26 lines

  1. What is RTTI ?
  2. --------------
  3.  
  4. The C++ language does not currently provide a mechanism for an object to
  5. determine its type at run-time. Some applications need run-time information
  6. such as class names and class inheritance structure.  In order to meet this
  7. need, the ANSI C++ committee has approved a proposal for a language extension
  8. to support Run Time Type Information (RTTI).  This proposal is described in
  9. "Standards: New Language Extensions" in the July-August issue of the C++
  10. Report.
  11.  
  12. The proposed RTTI support in C++ consists of three components:
  13.   1. The "dynamic_cast" operator which will allow automatic run-time checks
  14.      for type conversions.
  15.   2. The "typeid" operator which will return the type of an object at
  16.      run-time.
  17.   3. The option for user-defined libraries to extend the built-in RTTI
  18.      facilities.
  19.  
  20. The software contained in this package provides library support for all three
  21. of these features. This is a stop-gap implementation, designed to be used
  22. until commercial compilers support the RTTI extensions. It will allow users
  23. to experiment with RTTI. When commercial compiler support for RTTI becomes
  24. available, this software will still have value through its support for
  25. user-defined extensions.
  26.